import axios from "~/axios";

// 获取用户注册信息
export function getRegister(data) {
    return axios.get(`/user/register/`)
}

// 新增用户注册信息
export function postRegister(data) {
    return axios.post(`/user/register/`, data)
}

// 修改用户注册信息
export function putRegister(id, data) {
    return axios.put(`/user/register/${id}/`, data)
}

// 删除用户注册信息
export function deleteRegister(id) {
    return axios.delete(`/user/register/${id}/`)
}


//  登录
export function postUserLogin(username, password) {
    return axios.post('/user/login/', { username, password })
}